/*
 * events.h
 *
 *  Copyright (C) 2012  Pierre Beaucamp
 *
 *	This file is part of the Program CRAFTING
 *
 *  CRAFTING is free software: you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation, either version 3 of the License, or
 *  (at your option) any later version.
 *
 *  CRAFTING is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with CRAFTING.  If not, see <http://www.gnu.org/licenses/>.
 *
 */

#ifndef EVENTS_H_
#define EVENTS_H_

#include "SDL/SDL.h"

class events {

public:

					events			();
	virtual	 		~events			();

    virtual void 	onEvent			(SDL_Event* event);
    virtual void 	onInputFocus	();
    virtual void 	onInputBlur	();
    virtual void 	onKeyDown		(SDLKey sym, SDLMod mod, Uint16 unicode);
    virtual void 	onKeyUp			(SDLKey sym, SDLMod mod, Uint16 unicode);
    virtual void 	onMouseFocus	();
    virtual void 	onMouseBlur	();
    virtual void 	onMouseMove	(short mX, short mY, short relX, short relY, bool left, bool right, bool middle);
    virtual void 	onMouseWheel	(bool up, bool down);
    virtual void 	onLButtonDown	(short mX, short mY);
    virtual void 	onLButtonUp	(short mX, short mY);
    virtual void 	onRButtonDown	(short mX, short mY);
    virtual void 	onRButtonUp	(short mX, short mY);
    virtual void 	onMButtonDown	(short mX, short mY);
    virtual void 	onMButtonUp	(short mX, short mY);
    virtual void 	onJoyAxis		(Uint8 which, Uint8 axis, Sint16 value);
    virtual void 	onJoyButtonDown(Uint8 which, Uint8 button);
    virtual void 	onJoyButtonUp	(Uint8 which, Uint8 button);
    virtual void 	onJoyHat		(Uint8 which, Uint8 hat, Uint8 value);
    virtual void 	onJoyBall		(Uint8 which, Uint8 ball, Sint16 xrel, Sint16 yrel);
    virtual void 	onMinimize		();
    virtual void 	onRestore		();
    virtual void 	onResize		(short w, short h);
    virtual void 	onExpose		();
    virtual void 	onExit			();
    virtual void 	onUser			(Uint8 type, int code, void* data1, void* data2);

};

#endif /* EVENTS_H_ */
